-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: add docs related to contributing #171
Conversation
Also add pull request checklist. Add content to style guide.
- Move Git/GitHub stuff to its own file. - Move scenarios to their own file. - Add image.
@katestange are you reviewing this since you reviewed the last PR on this topic that (if I understand correctly) gave rise to this one? Or would you like me to? Just let me know. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great! I had some suggestions, but overall I think it's in excellent shape!
|
||
Here are the different scenarios you could find yourself in and what to do | ||
about them. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think maybe we could explain here what the goal is. Why do I want to do anything and not just leave it as is? Is this "how to get to the point of a PR given your current weird git setup"? Maybe an introductory paragraph saying that the goal is to be working on your own fork, on a branch devoted to this pull request, etc. (a bulleted list maybe). Then people can look at it and say, "oh, I see I'm not set up that way, what do I do?" and then start looking through the flowchart.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might also be helpful to have something like this (but shorter) in the main doc, saying why you might want to click on the flowchart.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- [Read about basic Git operations](./working-with-git-and-github#basic-git-operations). | ||
- 2.B.2: You are working on a different branch. | ||
- 2.B.2.A: You have made commits. | ||
- [Read about basic Git operations](./working-with-git-and-github#basic-git-operations). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems weird that the remedy here is to read some stuff. Should it say "congrats, you are all set up correctly, here's some useful info" or "read about these git operations because you aren't set up right, but I don't know how to help you"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- [Clone your fork](./working-with-git-and-github#clone-a-repo). | ||
- [Create a branch](./working-with-git-and-github#create-a-branch). | ||
- [Push a branch](./working-with-git-and-github#push-a-branch). | ||
- [Read about basic Git operations](./working-with-git-and-github#basic-git-operations). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything ends with "read about basic git operations" as if that's the final step. But I would have expected the final step to be something like "Now you are working on a dedicated branch on your own fork, congrats! Read about about basic git operations here (link) and get to work making a cool visualizer!"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed in 7a08b13.
- 1: You have a clone of a Numberscope repository. | ||
- 1.A: You haven't made changes. | ||
- [Create a fork](./working-with-git-and-github#create-a-fork). | ||
- [Clone your fork](./working-with-git-and-github#clone-a-repo). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
many of these links don't seem to work, did you need a file extension?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 7a08b13.
doc/pull-request-checklist.md
Outdated
changed files and no warnings/errors. | ||
- [ ] The PR builds by running npm run build. (This also checks type | ||
correctness.) There should be no errors, and for now the only allowed | ||
warning is the one about some assets being too big. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there's an issue about this assets warning (will it eventually go away?) then we should reference this file there so when that goes away this file is updated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Created #173.
doc/pull-request-checklist.md
Outdated
correctness.) There should be no errors, and for now the only allowed | ||
warning is the one about some assets being too big. | ||
- [ ] The PR passes all tests. (Right now, just by running npm run | ||
test:unit.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto, what's the mechanism for updating this when there are more tests? Maybe we should put a timestamp on these "right now" and "for now" comments? At least that way, someone who is looking at the file can tell how stale they are.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added timestamp and created #174.
doc/pull-request-checklist.md
Outdated
submitter list, but be sure to exercise as many randomly selected | ||
behaviors as you have time for, definitely including but not limited | ||
to the ones nominally affected by the PR. This should be done in | ||
`npm run preview` mode after a successful build. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks, i didn't know that about preview mode
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is Glen's writing, but yeah preview mode allows you to view the docsite as well as interact with frontscope. However, it's built, so no hot module reload.
```sh | ||
git stash pop | ||
``` | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in addition to or instead of the git stash apply?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of. Clarified in 8c5ac25.
``` | ||
|
||
The name of the remote is most likely `origin` if you are pushing to a fork of | ||
one of the Numberscope repositories. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add something about how you can view your remote names to double check (you told me that command on slack).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, I see you do something like that below, maybe you should reorganize / link so that info is available here and there somehow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added section on checking remotes in 4d7ced0.
way to do this is to navigate to the page of your fork of | ||
numberscope/frontscope and click "Sync fork" (see the picture below). | ||
![A screenshot of the Sync fork option](./doc/img/sync-fork.png) Another | ||
way to do this is to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like the screenshots!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! :)
@katestange, I believe I've addressed all of your feedback. Let me know if there's anything else I overlooked. Thanks! |
I just want to comment that someone (other than Liam) should look at the on-line documentation (as generated by either/both of |
Hi both, Glen, I did not think to do that. If you want to take a quick look and look over the PR as it stands, that would be great. I think it's looking good. |
OK, I am going to assume that all of the above conversations are resolved. But I am guessing you didn't examine the new collection of docs online, Liam, as the outline no longer corresponds well to the collection of pages available. The outline structure is set in the mkdocs.yml file, in the "nav" block. You will see, for example, that the nav block refers to doc/contributing.md, but there is no longer any such file, leading to a 404 as you navigate the outline. So that at least needs to change. And also, any page in doc/ that is not otherwise mentioned ends up in the "Other Information" category. So if that's not where you want it, you need to either mention it explicitly in nav, or at least have another pattern in nav that will match it (i.e., you could make a subdirectory of the ones you want under the Contributing heading, and then use a glob pattern to grab just those). You may just want to mention each one by its full file name, though, in the nav section, so that they come out in a logical order (if a pattern matches multiple files, I think they are just presented in alphabetical order, for example as with the Visualizers). Do you want to take a stab at reorganizing the nav section of the mkdocs.yml to present the new collection of files well? This is definitely something that should be done before merging. If you find the format/structure there unclear/difficult to use let me know and we can discuss how to make it more accessible. Thanks! |
Oh, and mkdocs reported the following warning:
so it looks like there's also still another dead link that needs fixing before a merge. Thanks for handling. |
Yeah, I didn't. I got too focused on making the docs themselves and didn't think of checking the docsite. Thank you for reminding us!
I would like to do this, but I am having trouble. When I do |
I blew away my |
Change titles in some of the docs so they look better in the sidebar. For #171 (comment)
So that the docsite looks good. Part of #171.
I took a stab at it in 7187a2f and b354337.
Addressed in e0bcd94. I also removed the checkboxes in the PR checklist (6f12825) because they don't render properly on the docsite and I thought it looked weird. Let me know if you think I should put them back since it's a checklist. @gwhitney, let me know if you like the ordering of the docs in the sidebar. |
Great, no more warnings. (And I am fine either way on the checkboxes.)
Thanks for all of your time and effort on this important PR! |
@gwhitney, I added your suggestions in the most recent 8 commits. |
Hang on, need to fix a warning. |
Okay, should be fine now. |
Made a couple tiny edits. Merging now. |
This PR adds:
CONTRIBUTING.md
(the main contributing file that also contains instructions for submitting a PR)doc/code-principles.md
(our "DRY" and "KISS" doc)doc/code-style.md
(our nascent code style stuff that isn't covered by ESLint and Prettier)doc/git-scenarios-and-what-to-do-about-them.md
(a flowchart for figuring out your Git issues)doc/pull-request-checklist.md
(PR checklists for submitters and reviewers)This PR removes:
doc/submitting-pull-requests.md
(added a section inCONTRIBUTING.md
)doc/contributing.md
(added content to newCONTRIBUTING.md
)